﻿using System.Reflection;

namespace Ue.Utility
{
    public static class AssemblyHelper
    {
        /// <summary>
        /// 提取程序集的名称
        /// </summary>
        /// <param name="fullName">程序集的完整形式全名称</param>
        /// <returns></returns>
        public static string ExtractAssemblyShortName(string fullName)
        {
            int index = fullName.IndexOf(',');
            if (index < 0)
            {
                return fullName;
            }

            return fullName.Substring(0, index);
        }
    }
}
